import React, { Component } from 'react';
import { NavLink } from 'react-router-dom'
class Index extends Component {
	render() {
		const { routes } = this.props
		return (
			<div style={{
				position: 'fixed',
				bottom: 0,
				left:0,
				width: '100vw',
				height: 36,
				display: 'flex',
				justifyContent: 'space-around',
				alignItems: 'center',
				backgroundColor: '#fff'
			}}>
				{
					routes.length > 0 && routes.map((v,i) => {
						return <NavLink key={ i } to={v.path}>{ v.name }</NavLink>
					})
				}
			</div>
		);
	}
}

export default Index;
